package com.ztc.ZtcTransportCapitalLog.bean;


import com.aqgj.util.BaseEntity;
import com.ztc.ZtcTransport.bean.ZtcTransport;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;

@Entity
@Table(name = "ztc_transport_capital_log")
public class ZtcTransportCapitalLog implements BaseEntity {

    private String id;//ID

    /**
     * 类型（1-提现;2-提现失败进账;3-车方公司购票进账;4-运营公司购票进账;5-地级公司购票进账;6-省级公司购票进账;
     *      7-车方公司退票出账;8-运营公司退票出账;9-地级公司退票出账;10-省级公司退票出账;11-车方公司退票违约金进账;
     *      12-运营公司退票违约金进账;13-地级公司退票违约金进账;14-省级公司退票违约金进账;15-车方公司退违约金出账;
     *      16-运营公司退违约金出账;17-地级公司退违约金出账;18-省级公司退违约金出账;19-快递公司收入;20-快递公司支出）
     */
    private String type;

    private String businessId;//业务ID（订单ID，提现ID）

    private java.math.BigDecimal money;//金额

    private java.math.BigDecimal afterBalance;//本次交易后余额

    private String remark;//备注

    private java.util.Date createTime;//记录创建时间

    private ZtcTransport ztcTransport;

    public void setId(String value){
        this.id = value;
    }
//    public void setTransportId(String value){
//        this.transportId = value;
//    }
    public void setType(String value){
        this.type = value;
    }
    public void setBusinessId(String value){
        this.businessId = value;
    }
    public void setMoney(java.math.BigDecimal value){
        this.money = value;
    }
    public void setAfterBalance(java.math.BigDecimal value){
        this.afterBalance = value;
    }
    public void setRemark(String value){
        this.remark = value;
    }
    public void setCreateTime(java.util.Date value){
        this.createTime = value;
    }

    public void setZtcTransport(ZtcTransport ztcTransport) {
        this.ztcTransport = ztcTransport;
    }

    @Id
    @GeneratedValue(generator = "system-uuid")
    @GenericGenerator(name = "system-uuid", strategy = "uuid")
    @Column(name ="id",unique=false,nullable=false,insertable=true,updatable=true,length=32)
    public String getId(){
        return this.id;
    }
//    @Column(name ="transport_id",unique=false,nullable=true,insertable=true,updatable=true,length=32)
//    public String getTransportId(){
//        return this.transportId;
//    }
    @Column(name ="type",unique=false,nullable=true,insertable=true,updatable=true,length=4)
    public String getType(){
        return this.type;
    }
    @Column(name ="business_id",unique=false,nullable=true,insertable=true,updatable=true,length=32)
    public String getBusinessId(){
        return this.businessId;
    }
    @Column(name ="money",unique=false,nullable=true,insertable=true,updatable=true,length=20)
    public java.math.BigDecimal getMoney(){
        return this.money;
    }
    @Column(name ="after_balance",unique=false,nullable=true,insertable=true,updatable=true,length=20)
    public java.math.BigDecimal getAfterBalance(){
        return this.afterBalance;
    }
    @Column(name ="remark",unique=false,nullable=true,insertable=true,updatable=true,length=255)
    public String getRemark(){
        return this.remark;
    }
    @Column(name ="create_time",unique=false,nullable=true,insertable=true,updatable=true,length=0)
    public java.util.Date getCreateTime(){
        return this.createTime;
    }

    @ManyToOne(fetch = FetchType.LAZY)
    @JoinColumn(name ="transport_id")
    public ZtcTransport getZtcTransport() {
        return ztcTransport;
    }
}
